You are here: Language Elements and Expressions > Numbers > Converting Between Numeric Types
When an expression expects one type of value but receives another, ProModel automatically takes care of converting between the two, so most often the difference will not matter. However, when ProModel expects an integer but receives a real value, it truncates the real value at the decimal point. For example, say the variable Integer1 is assigned the value 3.9, as in the following statement: Integer1=3.9. The variable Integer1 would hold the value 3, not 4. To round 3.9 when assigning to an integer variable would require the statement, Integer1=Round(3.9).
Converting from name-index numbers to the name of an element requires the ENT(), LOC(), and RES() functions as ProModel does not automatically convert numbers to names. For information on how to output the name of an element based on its name-index number, see String Expressions.